<?php

use think\facade\Route;

Route::rule('api/[:controller]/[:action]', '\app\frontend\controller\:controller@:action', '*');
